package com.guli.common.vo;

import lombok.Data;

import java.util.Objects;

@Data
public class Attr {

    private Long attrId;
    private String attrName;
    private String attrValue;

    public Attr() {
    }

    public Attr(Long attrId, String attrName, String attrValue) {
        this.attrId = attrId;
        this.attrName = attrName;
        this.attrValue = attrValue;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (!(o instanceof Attr)) return false;
        Attr attr = (Attr) o;
        return attrId.equals(attr.attrId) &&
                attrName.equals(attr.attrName);
    }

    @Override
    public int hashCode() {
        return Objects.hash(attrId, attrName);
    }
}
